<!DOCTYPE html>
<html>
<head>
<#include "/common/freemarker/include_css.ftl">
<title>服务号粉丝</title>
</head>

 
<body style="padding:10px">
    <div class="panel panel-default">
       <div class="panel-heading"><strong>服务号粉丝</strong></div>
        <div class="panel-body">
 
	          <div class="row" >
	              		<form action="<@context/>weixin/wxmpuserinfo/search.do" id="searchFromId" method="post" style="display:none"> <#-- 该ID需当参数传入分页的宏    -->
			                
				                <input type="hidden" name="search" value="search">                      <#-- 这里必须加上，不然不会进行条件查询，且name和value不能修改其他值       -->
				                <input type="hidden" name="pageId" id="pageId">                         <#-- 这里必须加上，不然分页模块会不正常，且id和name不能修改为其他值 --> 
				                <input type="hidden" name="pageMaxSize" id="pageMaxSize">                   <#-- 这里必须加上，不然修改显示条数会不正常，且id和name不能修改为其他值   -->
								 
								  
						        <div class="form-body query-form">	          
						                <#--
										<div class="col-xs-6 col-sm-4 query-item" >
									    <label class="control-label col-xs-5 col-sm-5">姓名</label>
										<div  class="col-xs-7 col-sm-7 ">
											<input type="text"   class="input-sm form-control clean" name="_s_lk_name" placeholder="" value='${ param["_s_lk_name"]?if_exists}'  />														
										</div>
										</div>
										<div class="col-xs-6 col-sm-4 query-item" >
										<label class="col-xs-5 col-sm-5"  for="name">报名时间大于</label>
										<div class="col-xs-7 col-sm-7 ">
											<input type="text" class="input-sm form-control clean"  date-picker" name="_d_ge_createTime" placeholder="" data-date-format="yyyy-mm-dd"  value='${ param["_d_ge_createTime"]?if_exists}' onclick="javascript:WdatePicker({dateFmt:'yyyy-MM-dd'});"  />																									
										</div>
										</div>
										<div class="col-xs-6 col-sm-4 query-item" >
										<label class="control-label col-xs-5 col-sm-5">报名时间小于</label>
										<div class="col-xs-7 col-sm-7 ">
											 <input type="text"  class="input-sm form-control clean"  date-picker" name="_d_led_createTime" placeholder="" data-date-format="yyyy-mm-dd" value='${ param["_d_led_createTime"]?if_exists}' onclick="javascript:WdatePicker({dateFmt:'yyyy-MM-dd'});"  />																										
										</div>
										</div>
										-->
							  			<div class="col-xs-6 col-sm-4 query-item" >
										<label class="control-label col-xs-5 col-sm-5">微信昵称</label>
										<div class="col-xs-7 col-sm-7 ">
											<input type="text"   class="input-sm form-control clean" id="_s_lk_nickname" name="_s_lk_nickname" placeholder="" value='${ param["_s_lk_nickname"]?if_exists}'>														
										</div>
										</div>
										<div class=" col-xs-12 col-sm-12">
													<div>			
														<center>																
									  	                <input type="button" class="btn    btn-sm btn-primary" id="btnQuery"  value="确定"/>&nbsp;
									  	                <#--
									  	                <input type="button" class="btn  btn-default  btn-sm" id="btnReset" value="重 置"/> 
									  	                -->
									  	                <a class="btn btn-sm btn-default"    href="#" onclick="javascript:$('#searchFromId').toggle();">隐藏</a>&nbsp;	   
														</center>		
													</div>
												 
										</div>
								</div>				                
			          </form>
		          
	            </div>
	            
	            <div class="row">
	            	<div class=" col-xs-12 col-sm-12">
					   	 <div class="btn-group-search-panel" role="group"   >
				        		 <a class="btn btn-sm btn-default" id="searchPanelBtn"  href="#" onclick="javascript:$('#searchFromId').toggle();"> <span class="fa fa-search">搜索</span> </a>	 
				         </div>
			         </div>
			    </div> 
			        
				<div id="listPageSpan">
		        </div>	
			         
	</div>
</div>

	 
	<#include "/common/freemarker/include_js.ftl">
	<script>
	      var listPageAjaxUrl= "<@context/>weixin/wxmpuserinfo/searchPageAjax.do";
	      
	      window.onload=function(){
	      	 listPageAjax();
	      }
	      function listPageAjax(){
	      	 	var data = $("#searchFromId").serialize();
				$.ajax({
					type: "post",
					url: listPageAjaxUrl,
					data: data,
					cache: false,
					success: function(html){
						$("#listPageSpan").html(html);
					}
				});
	      }
	      $("#btnReset").click(function() {
	    	  $(".clean").val("");
	      })
	      $("#btnQuery").click(function() {
	    	  listPageAjax();
	      }) 
	      $("#btnBack").click(function() { 
	      	 window.location.href="<@context/>site/event/search.do";
	      })     
 
    	function addRemark(uuid){
    	        //alert(1)
    			$("#uuid").val(uuid);
    			$("#myremark").val();
	       		var ajaxUrl="<@context/>weixin/wxmpuserinfo/getRemark.do";
	            var data = {"uuid":$("#uuid").val(),"myremark":$("#myremark").val()};
				$.ajax({
					type: "post",
					url: ajaxUrl,
					data: data,
					dataType: "json",
					cache: false,
					timeout:120000,
					success: function(json){ 
						$("#myremark").val(json.data);
						$("#publishModle").modal("toggle");
					}
				})	
				
    	}
    	function submitRemark(){
    		  	$('#remarkBtn').attr("disabled",true);
	       		var ajaxUrl="<@context/>weixin/wxmpuserinfo/submitRemark.do";
	            var data = {"uuid":$("#uuid").val(),"myremark":$("#myremark").val()};
				$.ajax({
					type: "post",
					url: ajaxUrl,
					data: data,
					dataType: "json",
					cache: false,
					timeout:120000,
					success: function(json){ 
					    if (json.status=="success"){
							 $('#publishResultMsg').html("保存成功！"); 
							 setTimeout('submitRemarkFinished()',500) 
		    			}else{
		    				$('#publishResultMsg').html(json.message); 
		    				$('#remarkBtn').attr("disabled",false);
		    			}
					},
					error:function(e){
						$('#publishResultMsg').html("保存失败"); 
						$('#remarkBtn').attr("disabled",false);
					}
				});
    	}
    	function submitRemarkFinished(){
    		 $('#publishModle').modal('hide'); 
    		 $('#remarkBtn').attr("disabled",false);
    	}
 
    </script>
</body>	 
</html>
